import request from '@/utils/request';

// 查询白名单列表
export function list(data: any): ApiPromise<ApiResponse> {
	return request({
		url: '/management/resourceWhitelist',
		method: 'post',
		data: data,
	});
}

// 新增白名单
export function add(data: any): ApiPromise<ApiResponse> {
	return request({
		url: '/management/resourceWhitelist/save',
		method: 'post',
		data: data,
	});
}

// 修改白名单
export function edit(data: any): ApiPromise<ApiResponse> {
	return request({
		url: '/management/resourceWhitelist',
		method: 'put',
		data: data,
	});
}

// 删除白名单
export function remove(ids: any): ApiPromise<ApiResponse> {
	return request({
		url: '/management/resourceWhitelist/delete/' + ids,
		method: 'delete',
	});
}
